package com.jiepos.mpos.biz.review.controller;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;

import com.jiepos.mpos.biz.review.service.MemReviewService;
import com.jiepos.mpos.biz.review.service.ReviewHomePageService;
import com.jiepos.mpos.biz.review.service.SettleAccountService;
import com.jiepos.mpos.core.controller.BaseController;

/**
 * 审核管理控制层
 * @ClassName: ReviewHomePageController
 * @Description: 审核管理控制层
 * @author 张磊
 * @date 2017年9月21日 下午3:03:34
 *
 */
@Controller
@RequestMapping("review")
public class ReviewHomePageController extends BaseController{

	@Autowired
	private ReviewHomePageService reviewHomePageService;
	
	@Autowired
	private MemReviewService memReviewService;
	
	@Autowired
	private SettleAccountService settleAccountService;
	
	/**
	 * 审核业务主页面
	 * @param request
	 * @param response
	 * @return
	 */
	@RequestMapping("/getReviewNum.do")
	public ModelAndView getReviewNum(HttpServletRequest request, HttpServletResponse response){
		
		Integer memberReviewNum = memReviewService.getMemberReviewNum(request);
		Integer accInfoChangeReviewNum = settleAccountService.getAccountReviewNum(request); 
		ModelAndView model = new ModelAndView("/module/review/reviewhomepage/reviewhomepage");
		model.addObject("memberReviewNum",memberReviewNum);
		model.addObject("accInfoChangeReviewNum",accInfoChangeReviewNum);
		return super.getDetail(request, response, model);
		
	}
	
	
}
